<?php

use Illuminate\Routing\Router;

Route::group([
	'prefix'        => 'admin/DesignerAuth',
	'namespace'     => 'Beerus\\Modules\\DesignerAuth\\Controllers',
	'middleware'    => [
		'web',
		'admin',
	],
], function (Router $router) {
	// 入驻设计师案例/资料审核列表
	$router->get('/{tab}', 'DesignerAuthController@index')->name('list');
	$router->get('/{tab}/create', 'DesignerAuthController@edit');
	$router->get('/{tab}/{id}/edit', 'DesignerAuthController@edit');
	$router->post('/{tab}/save', 'DesignerAuthController@save');
	$router->get('/detail/{uid}', 'DesignerAuthController@detail')->name('detail');
	$router->put('/{tab}/{id}', 'DesignerAuthController@editRemark');
	$router->get('/export/auth_data', 'DesignerAuthController@exportData');
	// 导出审核操作记录
	$router->get('/export/audit_log', 'AuditLogController@export');
	// 待开通认证
	$router->get('/wait_auth', 'WaitAuthController@index')->name('wait.list');
	// 认领、取消认领客户
	$router->get('/sale_bind/bind/{uid}', 'SaleBindController@bind');
	$router->get('/sale_bind/unbind/{uid}', 'SaleBindController@unbind');
	// 取消认证
//	$router->get('/cancel_auth/{uid}', 'CancelAuthController@cancelLayer');
//	$router->post('/cancel_auth/submit', 'CancelAuthController@submit');
	$router->post('/cancel_auth/{uid}', 'CancelAuthController@cancel');
	// 备注、补充说明填写
	$router->get('/remark/{uid}', 'AuditRemarkController@remarkLayer');
	$router->post('/remark/submit', 'AuditRemarkController@submit');
	// 案例审核
	$router->get('/case_pass/{uid}', 'CaseAuditController@pass');
	$router->get('/case_reject/{uid}', 'CaseAuditController@rejectLayer');
	$router->post('/case_audit/reject', 'CaseAuditController@reject');
	// 资料审核
	$router->get('/info_pass/{uid}', 'InfoAuditController@pass');
	$router->get('/info_reject/{uid}', 'InfoAuditController@rejectLayer');
	$router->post('/info_audit/reject', 'InfoAuditController@reject');
	// 认证服务开通
	$router->get('/services/{uid}', 'DesignerPayServiceController@index');
	$router->get('/open_service/{dsn}/{uid}', 'DesignerPayServiceController@openService');

	// 待认证列表
//	$router->get('/wait', 'DesignerAuthController@wait')->name('designer_auth.list');
//	$router->get('/list/create', 'DesignerAuthController@edit');
//	$router->get('/list/{id}/edit', 'DesignerAuthController@edit');
//	$router->post('/list/save', 'DesignerAuthController@save');
});
